package com.qd.pay.domain;

import com.cdqidi.util.page.BaseQuery;
import com.cdqidi.valid.group.DefaultGroup;
import com.cdqidi.valid.group.DeleteGroup;
import com.cdqidi.valid.group.UpdateGroup;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;


/**
 * 天府银行订单
 *
 * @author sjk
 */
@EqualsAndHashCode(callSuper = true)
@Getter
@Setter
public class OrderTfDTO extends BaseQuery {

    /**
     * 主键
     */
    @NotBlank(message = "订单ID不能为空", groups = {DeleteGroup.class, UpdateGroup.class})
    @Size(max = 50, message = "订单ID长度不能超过{max}位", groups = {DeleteGroup.class, UpdateGroup.class})
    private String orderId;
    /**
     * 服务商号
     */
    @NotBlank(message = "服务商号不能为空", groups = DefaultGroup.class)
    @Size(max = 10, message = "服务商号长度不能超过{max}位", groups = DefaultGroup.class)
    private String partner;
    /**
     * 特约商户号
     */
    @NotBlank(message = "特约商户号不能为空", groups = DefaultGroup.class)
    @Size(max = 10, message = "特约商户号长度不能超过{max}位", groups = DefaultGroup.class)
    private String subPartner;
    /**
     * 天府支付在渠道的商户订单号
     */
    @Size(max = 28, message = "天府支付在渠道的商户订单号长度不能超过{max}位", groups = DefaultGroup.class)
    private String payTransno;
    /**
     * 付款服务方
     */
    @Size(max = 16, message = "付款服务方长度不能超过{max}位", groups = DefaultGroup.class)
    private String bankType;
    /**
     * 支付渠道
     */
    @NotBlank(message = "支付渠道不能为空", groups = DefaultGroup.class)
    @Size(max = 32, message = "支付渠道长度不能超过{max}位", groups = DefaultGroup.class)
    private String transChannel;

    @Override
    public void freeData() {
        this.orderId = null;
        this.partner = null;
        this.subPartner = null;
        this.payTransno = null;
        this.bankType = null;
        this.transChannel = null;
        super.freeData();
    }
}
